home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.cs.arizona.edu
/
ftp.cs.arizona.edu.tar
/
ftp.cs.arizona.edu
/
icon
/
newsgrp
/
group96a.txt
/
000095_icon-group-sender _Wed Apr 17 13:49:11 1996.msg
< prev
next >
Wrap
Internet Message Format
|
1996-09-05
|
1KB
Received: by cheltenham.cs.arizona.edu; Wed, 17 Apr 1996 17:19:29 MST
Date: Wed, 17 Apr 1996 13:49:11 -0700
Message-Id: <199604172049.NAA10393@dfw-ix3.ix.netcom.com>
X-Sender: bobalex@ix.netcom.com
X-Mailer: Windows Eudora Pro Version 2.1.2
Mime-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
To: swampler@noao.edu, icon-group@cs.arizona.edu
From: Bob Alexander <bobalex@ix.netcom.com>
Subject: Re: Making a list out of a generated sequence
Errors-To: icon-group-errors@cs.arizona.edu
Status: O
> every tempList := put([], !"string")
That is a VERY COOL Icon idiom -- wish I'd thought of it!
It consumes a bit of time though, so for cases where that is bad the
old-fashioned way is better. I did some trivial timings of
every x := put([],1 to 500000)
vs.
x := []; every put(x,1 to 500000)
and came out with about 7.5 vs. 5.7 sec -- apparently the cost of doing 1/2M
assignments. Not that I'm likely to actually *notice* that in a real program...
-- Bob